//
//  ByBasketBallBigSmallView.m
//  caipiao_ios
//
//  Created by mc on 2018/8/20.
//  Copyright © 2018年 ZhangZhanbin. All rights reserved.
//

#import "ByBasketBallBigSmallView.h"

@implementation ByBasketBallBigSmallView

- (id)initWithFrame:(CGRect)frame{
    self = [super initWithFrame:frame];
    if (self) {
        
        
        UILabel *centerLabel = [[UILabel alloc] init];
        [self addSubview:centerLabel];
        [centerLabel mas_makeConstraints:^(MASConstraintMaker *make) {
            make.centerX.equalTo(self).offset(0);
            make.top.equalTo(self).offset(0);
            make.bottom.equalTo(self).offset(0);
            make.width.mas_equalTo(@66);
        }];
        centerLabel.textAlignment = NSTextAlignmentCenter;
        centerLabel.font = FONT(13);
        centerLabel.textColor = BY_TEXT_COLOR;
        centerLabel.text = @"200.5";
        
        
        UIButton *leftBtn = [UIButton buttonWithType:UIButtonTypeCustom];
        [self addSubview:leftBtn];
        [leftBtn mas_makeConstraints:^(MASConstraintMaker *make) {
            make.top.equalTo(self).offset(0);
            make.bottom.equalTo(self).offset(0);
            make.left.equalTo(self).offset(0);
            make.right.equalTo(centerLabel.mas_left).offset(0);
        }];
        leftBtn.backgroundColor = BY_THEME_COLOR;
        
        UIButton *rightBtn = [UIButton buttonWithType:UIButtonTypeCustom];
        [self addSubview:rightBtn];
        [rightBtn mas_makeConstraints:^(MASConstraintMaker *make) {
            make.top.equalTo(self).offset(0);
            make.bottom.equalTo(self).offset(0);
            make.left.equalTo(centerLabel.mas_right).offset(0);
            make.right.equalTo(self).offset(0);
        }];
        rightBtn.layer.borderColor = BY_LINE_COLOR.CGColor;
        rightBtn.layer.borderWidth = 1;
        
        
        
    }
    return self;
}

@end
